package com.pro.common.service.websocket.mq;

import com.pro.common.api.model.dto.UserAmountDTO;
import com.pro.framework.api.mq.IMqRabbitMqRoutingKey;
import com.pro.framework.mq.rabbit.MqRabbitPublisher;
import lombok.RequiredArgsConstructor;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
@RequiredArgsConstructor
public class WebsocketMqProducer {

    private final MqRabbitPublisher rabbitPublisher;

    public void sendWebsocketEvent(IMqRabbitMqRoutingKey routingKey,String json) {
        rabbitPublisher.send(routingKey, json);
    }

    public void sendWebsocketEvent(IMqRabbitMqRoutingKey routingKey, List<String> list) {
        rabbitPublisher.send(routingKey, list);
    }
}
